/*
 * File:   RoundRobinScheduler.h
 * Author: henrya
 *
 * Created on June 29, 2009, 6:12 AM
 */

#ifndef _ROUNDROBINSCHEDULER_H
#define	_ROUNDROBINSCHEDULER_H

#include "OSScheduler.h"

class Network;

class RoundRobinScheduler :public OSScheduler{
public:
    RoundRobinScheduler(Network* network, unsigned int q);
    virtual ~RoundRobinScheduler();
    virtual void doScheduling(bool deliveredMsg);
private:
    unsigned int q;
    unsigned int currRunningNodeIndex;
    bool doContextSwitch();
    virtual void childReset();
};

#endif	/* _ROUNDROBINSCHEDULER_H */

